package beautiful.butterfly.drds.data_exchange.statistics;


public enum Phase
{
    /**
     * task total运行的时间，前10为框架统计，后面为部分插件的个性统计
     */
    task_total(0),

    read_task_init(1),
    read_task_prepare(2),
    read_task_data(3),
    read_task_post(4),
    read_task_destroy(5),

    write_task_init(6),
    write_task_prepare(7),
    write_task_start(8),
    write_task_post(9),
    write_task_destroy(10),

    /**
     * sql_query: sql query阶段, 部分reader的个性统计
     */
    sql_query(100),
    /**
     * 数据从sql全部读出来
     */
    result_next_all(101),

    /**
     * only odps block close
     */
    odps_block_close(102),

    wait_read_time(103),

    wait_write_time(104),

    transformer_time(201);

    private int val;

    Phase(int val)
    {
        this.val = val;
    }

    public int toInt()
    {
        return val;
    }
}
